﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using yncTech.BusinessObjects;

public partial class Admin_Sys_Sys002 : AdminBasePage
{

    protected void PageChanged(object sender, DataGridPageChangedEventArgs e)
    {
        TSFunctionsCollection functions = new TSFunctionsCollection();
        if (drpSystem.SelectedIndex > 0)
        {
            functions.Query.Where(functions.Query.ParentID < 0 && functions.Query.SystemId == drpSystem.SelectedValue);
        }
        else
        {
            functions.Query.Where(functions.Query.ParentID < 0);
        }

        functions.Query.Load();

        pageGrid.DataSource = functions;
        pageGrid.DataBind();
    }
}